1. Field of the Invention
The present invention relates generally to a method and an apparatus for playing an animation in a mobile terminal, and more particularly, to a method and apparatus for playing an animation with respect to various web content in a web browser and a web application.
2. Description of the Related Art
A mobile terminal may be a necessity in modern people. That is, the mobile terminal is used regardless of age or sex, and has been used as a medium capable of performing wireless audio call and information exchange. In initial supply of the mobile terminal, the mobile terminal is recognized that it is simply carried and allows a user to perform a wireless call. With the development of technology, the mobile terminal provides various services and functions. For example, the mobile terminal is developed to a multi-media device capable of performing a phone book function, a morning call function, a music player function, a schedule management function, a digital camera function, and a wireless Internet service and provides various services.
Meanwhile, the web page is a document defined by a Hyper Text Markup Language (HTML) specification. A body of the web page may include various web contents such as image, moving images, and audios as well as texts. The web contents are suitably arranged in an HTML document by a tag associated with a layout to configure a web page. An initial HTML specification may configure only a static web page. In recent years, the HTML specification has been expanded for configuring a dynamic web page by using techniques such as Java Script and Cascading Style Sheets (CSS). For example, the recent HTML5 specification now supports web content without a separate plug-in, and allows a user to directly use various functions included in a mobile terminal.
Generally, to display a web page on a screen, a web browser reads outs an HTML document in order to load necessary resources. The web browser parses the loaded resources to configure a Document Object Model (DOM) tree) and a render tree. The web browser performs a layout operation and a painting operation with respect to respective web content included in the HTML document to make a web page, and then displays the web page on the screen.
However, an existing supported animation of web content has limitations.
For example, a key frame scheme is a technology for disclosing the animation of web content. The key frame scheme may express a dynamic animation with respect to the web content. However, because a motion pattern of the web content is fixed, the key frame scheme is not realistic. For example, the web content performs a reciprocating motion in a landscape direction or rotates clockwise around one point. Further, a scale of the web content is restrictive.
Accordingly, it takes great effort to produce a complicated animation, and it is difficult to express real motion. Further, it is difficult to provide a collided animation from moving objects.
While Java Script extends a range of expressing animation, for a contents manufacturer, cost and time are increased in order to make various animations using Java Script.
In addition, a technique for generating and playing an animation of web content in response to external input information has not yet been provided.